#ifndef APPLICATONENGINE_H
#define APPLICATONENGINE_H

#include <QObject>
#include <QQmlApplicationEngine>
#include <QQmlContext>

#include <QCoreApplication>
#include <QSettings>
#include <QDebug>

#include "config.h"
#include "modbuscontrol.h"
#include "printercontrol.h"
#include "scannercontrol.h"
#include "netmanager.h"
#include "languagecontrol.h"
#include "cutdatamodel.h"
#include "usb_processlist_model.h"

#include "Choose_Material_Height/material_height_manager.h"
#include "Order_Process_DataBase/order_process_manager.h"


class ApplicatonEngine :  public QQmlApplicationEngine
{
    Q_OBJECT

public:
    ApplicatonEngine(QObject *parent = nullptr);

    ~ApplicatonEngine();

    void setConnectParamater();

    void connectToDevice();

    // 注册到QML
    void registerMethod();

signals:

public slots:

private:

    // 料高选择数据库
    Material_Height_Manager* m_MaterialHeightManager;

    // 排料加工数据库
    Order_Process_Manager* m_OrderProcessManager;

    // 配置文件
    Config* m_Config;

    // PLC 控制类
    ModbusControl* m_PLC;

    // 打印机 控制类
    PrinterControl* m_Printer;

    // 扫码枪 控制类
    ScannerControl* m_Scanner;

    // 网络请求 控制类
    NetManager* m_NetManager;

    // 切割数据Model
    CutDataModel* m_CutModel = nullptr;

    // U盘料单切割数据
    USB_ProcessList_Model* m_USB_Process_Model = nullptr;

    // 语言控制类
    LanguageControl* m_Language;


};

#endif // APPLICATONENGINE_H
